package sjtu.rfid.rri.services.leaf.model;

import java.io.Serializable;

/**
 * Configuration of the queue
 * 
 * @author jinghao
 * 
 */
public class QueueConfig implements Serializable {

	/**
	 * 
	 */
	private static final long serialVersionUID = -6065479223252908018L;

	private String name;
	private String type;
	private String parameters;

	/**
	 * @return the name
	 */
	public String getName() {
		return name;
	}

	/**
	 * @param name
	 *            the name to set
	 */
	public void setName(String name) {
		this.name = name;
	}

	/**
	 * @return the type
	 */
	public String getType() {
		return type;
	}

	/**
	 * @param type
	 *            the type to set
	 */
	public void setType(String type) {
		this.type = type;
	}

	/**
	 * @return the parameters
	 */
	public String getParameters() {
		return parameters;
	}

	/**
	 * @param parameters
	 *            the parameters to set
	 */
	public void setParameters(String parameters) {
		this.parameters = parameters;
	}

	@Override
	public String toString() {
		StringBuilder sb = new StringBuilder();
		sb.append(type);
		sb.append(":");
		sb.append(name);
		if (null != parameters) {
			sb.append(";");
			sb.append(parameters);
		}
		return sb.toString();
	}
}
